/* eslint-disable */
// @ts-ignore
import { queryOptions, useMutation } from '@tanstack/vue-query';
import type { DefaultError } from '@tanstack/vue-query';
import request from '@/utils/request';
import { CustomRequestOptions } from '@/interceptors/request';

import * as apis from './weixinyonghuhuogonglve';
import * as API from './types';

/** 攻略分页 GET /tourism/client/c/wxstrategy/getstrategy */
export function pageUsingGet3QueryOptions(options: {
  // 叠加生成的Param类型 (非body参数openapi默认没有生成对象)
  params: API.pageUsingGET3Params;
  options?: CustomRequestOptions;
}) {
  return queryOptions({
    queryFn: async ({ queryKey }) => {
      return apis.pageUsingGet3(queryKey[1] as typeof options);
    },
    queryKey: ['pageUsingGet3', options],
  });
}

/** 攻略详情 GET /tourism/client/c/wxstrategy/getstrategyinfo */
export function getStrategyInfoUsingGetQueryOptions(options: {
  // 叠加生成的Param类型 (非body参数openapi默认没有生成对象)
  params: API.getStrategyInfoUsingGETParams;
  options?: CustomRequestOptions;
}) {
  return queryOptions({
    queryFn: async ({ queryKey }) => {
      return apis.getStrategyInfoUsingGet(queryKey[1] as typeof options);
    },
    queryKey: ['getStrategyInfoUsingGet', options],
  });
}

/** 是否点赞 GET /tourism/client/c/wxstrategy/isuserlike */
export function isUserLikeUsingGetQueryOptions(options: {
  // 叠加生成的Param类型 (非body参数openapi默认没有生成对象)
  params: API.isUserLikeUsingGETParams;
  options?: CustomRequestOptions;
}) {
  return queryOptions({
    queryFn: async ({ queryKey }) => {
      return apis.isUserLikeUsingGet(queryKey[1] as typeof options);
    },
    queryKey: ['isUserLikeUsingGet', options],
  });
}

/** 点赞 GET /tourism/client/c/wxstrategy/like */
export function likeUsingGetQueryOptions(options: {
  // 叠加生成的Param类型 (非body参数openapi默认没有生成对象)
  params: API.likeUsingGETParams;
  options?: CustomRequestOptions;
}) {
  return queryOptions({
    queryFn: async ({ queryKey }) => {
      return apis.likeUsingGet(queryKey[1] as typeof options);
    },
    queryKey: ['likeUsingGet', options],
  });
}
